<!-- application/views/scripts/tblcompany/index.phtml -->
<p><a href="<?php
echo $this->url(
        array(
    'controller' => 'tblcompany',
    'action' => 'sign'
        ), 'default', true)
?>">Ajouter une companie</a></p>
<br>
<br><br>

<table cellpadding="0" cellspacing="0" id="tab" summary="Liste des companies">
    <caption><br>Liste des companies<br><br></caption>
    <colgroup>
        <col span="1" id="navcol" />
        <col span="1" id="numcol" />
    </colgroup>

    <thead>
        <tr>
            <th>ID</th>
            <th id="nb" abbr="Nb" scope="col">Numéro SIRET</th>
            <th id="nb" abbr="Nb" scope="col">Code Société</th>
            <th id="nb" abbr="Nb" scope="col">Nom</th>
            <th id="nb" abbr="Nb" scope="col">Description</th>
            <th id="nb" abbr="Nb" scope="col">Adresse</th>
            <th id="nb" abbr="Nb" scope="col">Code postal</th>
            <th id="nb" abbr="Nb" scope="col">Pays</th>
            <th id="nb" abbr="Nb" scope="col">Tel</th>
            <th id="nb" abbr="Nb" scope="col">Fax</th>
            <th id="nb" abbr="Nb" scope="col">Email</th>
            <th id="nb" abbr="Nb" scope="col">Active</th>
            <th id="nb" abbr="Nb" scope="col">Fournisseur</th>
            <th id="nb" abbr="Nb" scope="col">Client</th>
            <th id="nb" abbr="Nb" scope="col">Level</th>
            <th id="nb" abbr="Nb" scope="col">Mis à jour</th>
        </tr>
    </thead>
    <tbody>



        <?php foreach ($this->entries as $entry): ?>
            <?php
            if ($entry->active == 'Y') {
                echo '<tr>';
            } else {
                echo '<tr style="text-decoration:line-through">';
            }
            ?>   
        <td><?php echo $this->escape($entry->id) ?></td>
        <td><?php echo $this->escape($entry->siret) ?></td>
        <td><?php echo 'C000' . $this->escape($entry->id) ?></td>
        <td><?php echo $this->escape($entry->nom) ?></td>
        <td><?php echo $this->escape($entry->description) ?></td>
        <td><?php echo $this->escape($entry->adresse01) ?></td>
        <td><?php echo $this->escape($entry->codepostal01) ?></td>
        <td><?php echo $this->escape($entry->pays01) ?></td>
        <td><?php echo $this->escape($entry->tel01) ?></td>
        <td><?php echo $this->escape($entry->fax01) ?></td>
        <td><?php echo $this->escape($entry->email01) ?></td>
        <td><?php echo $this->escape($entry->active) ?></td>
        <td><?php echo $this->escape($entry->fournisseur) ?></td>
        <td><?php echo $this->escape($entry->client) ?></td>
        <td><?php echo $this->escape($entry->level) ?></td>
        <td><?php echo $this->escape($entry->last_updated_on) ?></td>
        <td align="center"><a href="<?php echo $this->url(array('controller' => 'tblcompany', 'action' => 'edit', 'id' => $entry->id)); ?>"><img src="<?php echo $this->baseUrl() . "/images/edit.png" ?>"></a>
        <td><a href="<?php echo $this->url(array('controller' => 'tblcompany', 'action' => 'delete', 'delete_id' => $entry->id)); ?>"><img src="<?php echo $this->baseUrl() . "/images/trash.png" ?>"></a>

            </tr>
        <?php endforeach ?>
        <!--?php endforeach ?-->
        </tbody>
</table>